/* 基础样式 */
:root {
    --bg-primary: #f8f9fa;
    --bg-secondary: #ffffff;
    --text-primary: #333;
    --text-secondary: #666;
    --border-color: #eaeaea;
    --shadow-color: rgba(0, 0, 0, 0.1);
    --accent-color: #4CAF50;
    --accent-light: rgba(76, 175, 80, 0.1);
    --modal-overlay: rgba(0, 0, 0, 0.2);
    --transition-theme: all 0.3s ease;
}

[data-theme="dark"] {
    --bg-primary: #1a1a1a;
    --bg-secondary: #2d2d2d;
    --text-primary: #ffffff;
    --text-secondary: #b3b3b3;
    --border-color: #404040;
    --shadow-color: rgba(0, 0, 0, 0.3);
    --accent-color: #6dd370;
    --accent-light: rgba(109, 211, 112, 0.1);
    --modal-overlay: rgba(0, 0, 0, 0.4);
}

body {
    min-height: 600px;
    margin: 0;
    padding: 0;
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, sans-serif;
    background: var(--bg-primary);
    color: var(--text-primary);
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
    overflow-x: hidden;
    width: 100%;
    max-width: 100%;
    box-sizing: border-box;
    transition: var(--transition-theme);
}

.container {
    padding: 16px;
    background: linear-gradient(135deg, var(--bg-secondary), var(--bg-secondary));
    min-height: 100vh;
    box-sizing: border-box;
    position: relative;
    z-index: 1;
    width: 100%;
    max-width: 100%;
    overflow-x: hidden;
}

/* 模态框基础样式 */
.modal {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    background: rgba(0, 0, 0, 0.2);
    z-index: 1000;
    backdrop-filter: blur(8px);
}

.modal-content {
    position: fixed;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    background: white;
    width: 90vw;
    max-width: 800px;
    min-width: 600px;
    height: 90vh;
    border-radius: 20px;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.1);
    animation: modalFadeIn 0.3s ease;
    overflow: hidden;
    display: flex;
    flex-direction: column;
}

@keyframes modalFadeIn {
    from {
        opacity: 0;
        transform: translate(-50%, -45%);
    }
    to {
        opacity: 1;
        transform: translate(-50%, -50%);
    }
}

.modal-header {
    padding: 20px 24px;
    border-bottom: 1px solid #f0f0f0;
    display: flex;
    justify-content: space-between;
    align-items: center;
    background: #ffffff;
}

.modal-header h2 {
    margin: 0;
    font-size: 18px;
    color: #333;
    display: flex;
    align-items: center;
    gap: 10px;
    font-weight: 600;
}

.modal-header h2 i {
    color: #4CAF50;
    font-size: 20px;
}

.close-btn {
    background: none;
    border: none;
    color: #999;
    cursor: pointer;
    padding: 8px;
    border-radius: 50%;
    width: 36px;
    height: 36px;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.2s ease;
}

.close-btn:hover {
    background: #f5f5f5;
    color: #666;
    transform: rotate(90deg);
}

.modal-body {
    padding: 24px;
    overflow-y: auto;
    flex: 1;
    background: #ffffff;
}

/* 通用按钮样式 */
.button-group {
    display: flex;
    gap: 10px;
    margin-bottom: 20px;
    flex-wrap: wrap;
}

.action-btn {
    padding: 10px 20px;
    border: 1px solid #eaeaea;
    border-radius: 10px;
    background: #ffffff;
    color: #666;
    cursor: pointer;
    transition: all 0.2s ease;
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 14px;
    font-weight: 500;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.02);
}

.action-btn i {
    font-size: 16px;
    color: #4CAF50;
}

.action-btn:hover {
    background: #4CAF50;
    color: white;
    border-color: #4CAF50;
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(76, 175, 80, 0.15);
}

.action-btn:hover i {
    color: white;
}

.action-btn:active {
    transform: translateY(0);
    box-shadow: none;
}

/* 激活状态 */
.action-btn.active {
    background: #4CAF50;
    color: white;
}

.action-btn.active i {
    color: white;
}

/* 滚动条美化 */
::-webkit-scrollbar {
    width: 8px;
    height: 8px;
}

::-webkit-scrollbar-track {
    background: #f5f5f5;
    border-radius: 4px;
}

::-webkit-scrollbar-thumb {
    background: rgba(76, 175, 80, 0.2);
    border-radius: 4px;
    transition: all 0.2s ease;
}

::-webkit-scrollbar-thumb:hover {
    background: rgba(76, 175, 80, 0.3);
}